<?php
namespace App\Http\Requests\User;

use App\Http\Requests\Request;

/**
 * 第三方登录验证
 *
 * @Package App\Http\Requests\User
 * @author zx
 * @date 2018-11-19
 */
class Author2Request extends Request {

    public function rules():array
    {
        return [
            'code' => 'required',
            'state' => 'required',
        ];
    }

    /**
     * 定义表单验证提示信息
     *
     * @author zx
     * @date 2018-11-19
     * @return array
     */
    public function messages():array
    {
        return [
            'code.required' => '授权码错误',
            'state.required' => '授权项错误',
        ];
    }
}